import { createRouter, createWebHashHistory } from 'vue-router'
// import HomeView from '../views/HomeView.vue'
import GradeManager from '@/views/student/GradeManager.vue'
import manageStudent from '@/views/student/StudentManager.vue'
import manageTeacher from '@/views/teacher/TeacherManager.vue'
import addStudent from '@/views/student/AddStudent.vue'
import addTeacher from '@/views/teacher/AddTeacher.vue'
import AaaaB from '@/views/AaaaB.vue'
import HomeView from '@/views/HomeView.vue'
const routes = [
  {
    path: '/',
    name: 'home',
    component: HomeView,//要改
    
  },
  {
    path: '/manage',
    name: 'manage',
    component: () => import(/* webpackChunkName: "about" */ '../views/ManageView.vue'),
    children:[
      {
        path:'/managegrade',
        component:GradeManager
      },

      {
        path:'/managestudent',
        component:manageStudent
      },
      {
        path:'/addstudent',
        component:addStudent
      },
      {
        path:'/addteacher',
        component:addTeacher
      },
      {
        path:'/manageteacher',
        component:manageTeacher
      },
      {
        path: '/managestudents/:id',
        component: AaaaB
      },
    ]
  },

]

const router = createRouter({
  history: createWebHashHistory(),
  routes
})

export default router
